id/email
password
forgot password | create account
about | help | prefs
ReadingBatcode reading practice

 

 

Athenian: Loopsfor_loop3

prev  |  next  |  chance

Determine the value returned by the function.
by Bernie '21

def count_int(paramlist):
    num=0
    length=len(paramlist)
    for i in range(length):
        txt=paramlist[i]
        if type(txt) is int:
            num += 1
    return num
Function Call  Return Value
count_int([5, 10, "hi"])
count_int([14.6, "watermelon", "fish"])
count_int([-1, 11, 56])
count_int(["Pangolin", 10, "Catfish"])

Experiment with this code on Gitpod.io

⬅ Back